<template>
  <div id="app">
    <header class="header">
      <div class="nav-container">
        <el-menu 
          mode="horizontal" 
          :router="true"
          :default-active="activeMenu"
          background-color="transparent"
          text-color="#ffffff"
          active-text-color="#ffd04b"
        >
          <div class="logo">La Cuisine</div>
          
          <el-menu-item index="/">首页</el-menu-item>
          <el-menu-item index="/menu">特色菜单</el-menu-item>
          
          <el-menu-item 
            index="/cart" 
            class="cart-item"
          >
            <el-icon :size="20"><shopping-cart /></el-icon>
            <span class="cart-text">购物车</span>
          </el-menu-item>
        </el-menu>
      </div>
    </header>

    <main>
      <router-view />
    </main>
  </div>
</template>

<style scoped>
#app {
  min-height: 100vh;
  font-family: 'Playfair Display', 'Helvetica Neue', Helvetica, 'PingFang SC', Arial, sans-serif;
}

.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
}

.nav-container {
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(10px);
}

.logo {
  float: left;
  margin: 0 30px;
  line-height: 60px;
  font-size: 24px;
  font-family: 'Playfair Display', serif;
  color: #ffd04b;
  font-style: italic;
}

.el-menu--horizontal {
  border: none !important;
  display: flex;
  align-items: center;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 20px;
  background-color: transparent !important;
}

.el-menu-item {
  font-size: 16px;
  letter-spacing: 1px;
  transition: all 0.3s ease;
  
  &:hover {
    color: #ffd04b !important;
    background-color: rgba(255, 255, 255, 0.1) !important;
  }
}

.cart-item {
  margin-left: auto;
}

.cart-text {
  margin-left: 8px;
  font-weight: 500;
}

main {
  padding-top: 60px;
}

/* 响应式适配 */
@media (max-width: 768px) {
  .logo {
    margin: 0 15px;
    font-size: 20px;
  }
  
  .el-menu-item {
    padding: 0 12px;
    font-size: 14px;
  }
  
  .cart-text {
    display: none;
  }
}
</style>